package StudentScore;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

public class StudentTest {
    static List<Student> list = new ArrayList<Student>();

    public static void StudentList() {
        Student stu1 = new Student("210401", "张三", "男", 20, 77);
        Student stu2 = new Student("210405", "娇娇", "女", 20, 90);
        Student stu3 = new Student("210406", "芬芬", "女", 22, 92);
        Student stu4 = new Student("210407", "啾啾", "女", 21, 89);
        Student stu5 = new Student("210408", "橙橙", "女", 20, 85);
        Collections.addAll(list, stu1, stu2, stu3, stu4, stu5);
    }

    public static void main(String[] args) {
        StudentList();
        System.out.println(list);
        System.out.println("Java的平均分是:"+" " + Test.getAvg(list));
        System.out.println("Java的最高分是:"+" "+ Test.getMax(list));
        System.out.println("Java的最低分是:"+" " + Test.getMin(list));
    }
}
